﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/SiteWithControlAccess.Master"
    Inherits="System.Web.Mvc.ViewPage<IQueryable<ProjetoComperio.DataLayer.Entities.Proposal>>" %>
    
<%@ Import Namespace="ProjetoComperio.Framework.Web.Security.UrlEncrypt" %>
<%@ Import Namespace="ProjetoComperio.DataLayer.Entities" %>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <h2>
        Minhas Propostas
    </h2>
    <div align="right">
        <%= Html.ActionLink("Novo","Create","Proposal") %>
    </div>
    <div class="Grid">
    <%= Html.Grid(Model).Columns(
           column => 
           {
               column.For(x => x.Title).Named("Título");
               column.For(x => x.Description).Named("Descrição");
               column.For(x => Html.ActionLink("Editar", "Edit", new { id = URLEncrypt.EncryptToString(x.ProposalID.ToString()) })
                   ).DoNotEncode().Attributes(x => new Hash(style => "font-weight:bold"));
           }).Attributes(Style =>  "width:100%").Empty("Não existem aplicações cadastradas.")
    %>
    </div>
    <br />
    <br />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="head" runat="server">
</asp:Content>
